package com.fzkjjt.storage.controller;

import com.fzkjjt.storage.service.StorageService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @program: seata-simple
 * @description:
 * @author: FangZhen
 * @create: 2020-10-14 15:53
 **/
@RestController
public class StorageController {

    @Autowired
    private StorageService storageService;

    @GetMapping("/deduct")
    public String deduct() {
        storageService.deduct("001", 1);
        return "storage_success";
    }
}
